#!/usr/bin/python

import os, sys
from pydonet.formats.dbridge import ADF

STORAGETYPE = {
  'F':  'FTS-0001',
  'Q':  'QuickBBS',
  'N':  'Passthru'
}

AREATYPE = {
  'E':  'Echomail',
  'L':  'Local'
}

def main():
  fd = open(sys.argv[1])
  areas = ADF.parse_stream(fd)
  fd.close()

  anum = 0
  for area in areas:
    anum += 1
    if not area.allocated: continue
    print '[%03d]' % anum, '%(areaName)s: %(areaDesc)s' % area
    print ' ' * 5, '%(storage)s %(kind)s area in %(directoryPath)s' % area

if __name__ == '__main__': main()

